package io;

import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.PrintWriter;

public class WriteStringDemo2 {
    public static void main(String[] args) throws FileNotFoundException {
        FileOutputStream out = new FileOutputStream("note.txt");
        PrintWriter pw = new PrintWriter(out);
        pw.println("hello world");
        pw.println("hello world");
        System.out.println("输出完毕");
        pw.close();
    }
}
